package com.xy.p2p.model;


/**
 * Tmemberassetaccountdetails entity. @author MyEclipse Persistence Tools
 */

public class Tmemberassetaccountdetails implements java.io.Serializable,Comparable<Tmemberassetaccountdetails> {

	//充值方向 -1：借（出金），1：贷（入金）
	public static final int TMEMBERASSETACCOUNTDETAIL_BORROWING_IN=1;
	public static final int TMEMBERASSETACCOUNTDETAIL_BORROWING_OUT=-1;
	//交易类型8：借款服务费 13：借入 12：借出 14：还款 2：本金收入 9：借款管理费 3：利息收入
	public static final int TRANTYPE_SERVICEFEE=8;
	public static final int TRANTYPE_BORROWIN=13;
	public static final int TRANTYPE_BORROWOUT=12;
	public static final int TRANTYPE_PAYMONEY=14;
	public static final int MANAGEMENTFEE=9;
	public static final int TRANTYPE_MIMONEY=2;
	public static final int TRANTYPE_INST=3;
	public static final int WITHDRAW=4;
	public static final int WITHDRAW_FEE=6;
	public static final int ACCOUNT_CHANGE=25;
	public static final int RECHRAGE_FEE=5;
	//余额贷
	public static final int YED_BORROW_OUT=26;
	public static final int YED_CAPITAL_IN=27;
	public static final int YED_INST_IN=28;
	public static final int YED_EARLY_SERVER_FEE=29;
	public static final int YED_INST_OUT=30;
	public static final int YED_CAPITAL_OUT=31;
	public static final int YED_BORROW_IN=32;
	
	
	// Fields

	private Long maadid;
	private Tmember Tmember;
	private Double tranamount;
	private Integer borrowing;
	private Integer trantype;
	private java.util.Date trandatetime;
	private String otherside;
	private String remark;
	
	private Tfinanceinfo tfinanceinfo;

	// Constructors

	/** default constructor */
	public Tmemberassetaccountdetails() {
	}

	/** full constructor */
	public Tmemberassetaccountdetails(Tmember Tmember, Double tranamount, Integer borrowing, Integer trantype, java.util.Date trandatetime, String otherside, String remark) {
		this.Tmember = Tmember;
		this.tranamount = tranamount;
		this.borrowing = borrowing;
		this.trantype = trantype;
		this.trandatetime = trandatetime;
		this.otherside = otherside;
		this.remark = remark;
	}

	// Property accessors

	public Long getMaadid() {
		return this.maadid;
	}

	public void setMaadid(Long maadid) {
		this.maadid = maadid;
	}

	public Tmember getTmember() {
		return this.Tmember;
	}

	public void setTmember(Tmember Tmember) {
		this.Tmember = Tmember;
	}

	public Double getTranamount() {
		return this.tranamount;
	}

	public void setTranamount(Double tranamount) {
		this.tranamount = tranamount;
	}

	public Integer getBorrowing() {
		return this.borrowing;
	}

	public void setBorrowing(Integer borrowing) {
		this.borrowing = borrowing;
	}

	public Integer getTrantype() {
		return this.trantype;
	}

	public void setTrantype(Integer trantype) {
		this.trantype = trantype;
	}

	public java.util.Date getTrandatetime() {
		return this.trandatetime;
	}

	public void setTrandatetime(java.util.Date trandatetime) {
		this.trandatetime = trandatetime;
	}

	public String getOtherside() {
		return this.otherside;
	}

	public void setOtherside(String otherside) {
		this.otherside = otherside;
	}

	public String getRemark() {
		return this.remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}

	public Tfinanceinfo getTfinanceinfo() {
		return tfinanceinfo;
	}

	public void setTfinanceinfo(Tfinanceinfo tfinanceinfo) {
		this.tfinanceinfo = tfinanceinfo;
	}

	@Override
	public int compareTo(Tmemberassetaccountdetails o) {
		return (int)(o.getTrandatetime().getTime()/60000-this.getTrandatetime().getTime()/60000);
	}


}